package org.tysite.tyservice.example.jsonview.dto;

import com.fasterxml.jackson.annotation.JsonView;

import java.io.Serializable;

/**
 * 模拟对象类型
 * @author tysite
 * @date 2020/4/1 0001
 */
public class JsonViewTypeDTO implements Serializable {
    private static final long serialVersionUID = -9120646499804570599L;
    
    public interface ListView {}
    
    /** 类型id */
    @JsonView({ListView.class})
    private Integer id;
    /** 类型名称 */
    @JsonView({ListView.class})
    private String name;
    
    public Integer getId() {
        return id;
    }
    
    public void setId(Integer id) {
        this.id = id;
    }
    
    public String getName() {
        return name;
    }
    
    public void setName(String name) {
        this.name = name;
    }
    
    @Override
    public String toString() {
        return "JsonViewTypeDTO{" +
            "id=" + id +
            ", name='" + name + '\'' +
            '}';
    }
}
